package net.wanho.shop.controller;

import lombok.RequiredArgsConstructor;
import net.wanho.shop.entity.Cate;
import net.wanho.shop.service.CateService;
import net.wanho.shop.vo.R;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * Author：汤小洋
 * Date：2025-09-24 9:09
 * Description：<描述>
 */
@RestController
@RequestMapping("/cate")
@RequiredArgsConstructor
public class CateController {

    private final CateService cateService;

    @GetMapping
    public R list() {
        List<Cate> list = cateService.list();
        return R.success(list);
    }


}
